#ifndef PIcontrol_h
#define PIcontrol_h

#include "Arduino.h"
#include <Quaternion.h>
#include <PIcontrol.h>
#include <FP_math.h>

class INU 
{
  public:

    INU(void);

    void update(int accel[], int gyro[], int v_in(), int compass, int dt);

    int gravity;
    int heading;
    int headGain, headShift;
    IMU attitude;

    Vector3 gyroOffset, accelOffset, velocity, bodyVelocity;

    PIVinteg vIntegrator;
    PIVcontrol accelOffsetPI;
    PIVlowGain gyroOffsetPI;
    PIcontrol headingPI;


};

#endif
